// 系统管理路由
const routers = [
  {
    path: '/system',
    name: '系统管理',
    visible: true,
    icon: 'el-icon-s-tools',
    level: 2,
    component: () => import('../shared/index.vue'),
    children: [
      {
        path: 'user',
        name: '用户管理',
        meta: { parentTitle: '权限管理', title: '用户管理', path: '/system/user', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/user/index.vue'], resolve),
      },
      {
        path: 'role',
        name: '角色管理',
        meta: { parentTitle: '权限管理', title: '角色管理', path: '/system/role', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/role/index.vue'], resolve),
      },
      {
        path: 'post',
        name: '岗位管理',
        meta: { parentTitle: '权限管理', title: '岗位管理', path: '/system/post', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/post/index.vue'], resolve),
      },
      {
        path: 'dept',
        name: '部门管理',
        meta: { parentTitle: '权限管理', title: '部门管理', path: '/system/dept', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/dept/index.vue'], resolve),
      },
      // ------
      {
        path: 'menu',
        name: '菜单管理',
        meta: { parentTitle: '系统管理', title: '菜单管理', path: '/system/menu', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/menu/index.vue'], resolve),
      },
      {
        path: 'config',
        name: '参数设置',
        meta: { parentTitle: '系统管理', title: '参数设置', path: '/system/config', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/config/index.vue'], resolve),
      },
      {
        path: 'dict',
        name: '字典管理',
        meta: { parentTitle: '系统管理', title: '字典管理', path: '/system/dict', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/dict/index.vue'], resolve),
      },
      {
        path: 'dictData/:dictId',
        name: '字典管理',
        meta: { ancestorTitle: '系统管理', parentTitle: '字典管理', title: '字典数据', path: '/system/dictData', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/dict/data.vue'], resolve),
      },
      {
        path: 'cloud',
        name: '云存储配置',
        meta: { parentTitle: '系统管理', title: '云存储配置', path: '/system/cloud', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/cloud/index.vue'], resolve),
      },
      {
        path: 'sms',
        name: '短信配置',
        meta: { parentTitle: '系统管理', title: '短信配置', path: '/system/sms', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/sms/index.vue'], resolve),
      },
      {
        path: 'editor',
        name: '富文本',
        meta: { parentTitle: '系统管理', title: '富文本', path: '/system/editor', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/editor/index.vue'], resolve),
      },
      {
        path: 'file',
        name: '文件管理',
        meta: { parentTitle: '系统管理', title: '文件管理', path: '/system/file', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/file/index.vue'], resolve),
      },
      {
        path: 'region',
        name: '行政区域',
        meta: { parentTitle: '系统管理', title: '行政区域', path: '/system/region', visible: true, keepalive: false },
        component: resolve => require(['../pages/system/region/index.vue'], resolve),
      }
    ]
  }
]

export default routers